From: Antoine Musso Date: Sat, 18 Feb 2012 10:57:34 +0000 (+0000) Subject: (bug 34421) avoid duplicate Subject headers in mail X-Git-Tag: 1.31.0-rc.0~24640 X-Git-Url: http://git.cyclocoop.org/%28%5B%5E/404?a=commitdiff_plain;h=d8ab214e02e59e580a1b680b5f43d8260bdf03d2;p=lhc%2Fweb%2Fwiklou.git (bug 34421) avoid duplicate Subject headers in mail r93397 duplicated the Subject header since it was passed both as an argument of mail() and in the additional headers array. This is r111765 done right. Tested using both Pear and mail() methods. --- diff --git a/includes/UserMailer.php b/includes/UserMailer.php index d72f1fd12a..88a7d6130e 100644 --- a/includes/UserMailer.php +++ b/includes/UserMailer.php @@ -244,6 +244,8 @@ class UserMailer { $endl = "\n"; } + # Subject header is unneeded since it an argument of mail() + unset( $headers['Subject'] ); $headers = self::arrayToHeaderString( $headers, $endl ); wfDebug( "Sending mail via internal mail() function\n" );